package kgame5.kgui.gameui.digi {
import flash.display.MovieClip;

/**
 * @author kk
 * 一个数字
 */
public class ADigiX {
	private var 
		mc:MovieClip,
			mc_strip:MovieClip;
	private var cellWidth:int;
	public function ADigiX(mc:MovieClip){
		this.mc=mc;
		mc_strip=mc.mc_strip;
		cellWidth=mc_strip.width/10;
	}
	public function show(value:int){
		mc.visible=true;
		mc_strip.x=-cellWidth*value;
	}
	public function hide(){
		mc.visible=false;
	}
	public function move(x:int){
		mc.x=x;
		//mc.y=y;
	}
	
	//进行一下便宜，这个是为了对其用的
	public function ofsX(p_ofsX:int){
		mc.x-=p_ofsX;
	}
}
}
